class Car<T> {
	name: T;
	add: (x: T, y: T) => T;
}

let car1 = new Car<number>();
car1.name = 0;
car1.add = function (x, y) {
	return x + y;
};